package com.durian.base.rxhttp.param


/**
 * 说明：Method
 * <p/>
 * 作者：Fanly
 * <p/>
 * 类型：Class
 * <p/>
 * 时间：2020/04/24 15:55
 * <p/>
 * 版本：version 1.0
 */
enum class Method {

    GET, HEAD, POST, PUT, PATCH, DELETE;

    fun isGet(): Boolean {
        return name == "GET"
    }

    fun isHead(): Boolean {
        return name == "HEAD"
    }

    fun isPost(): Boolean {
        return name == "POST"
    }

    fun isPut(): Boolean {
        return name == "PUT"
    }

    fun isPatch(): Boolean {
        return name == "PATCH"
    }

    fun isDelete(): Boolean {
        return name == "DELETE"
    }

}